home *** CD-ROM | disk | FTP | other *** search
- #include <stdio.h>
-
-
- #include <stdio.h>
- #ifndef OS_2
- #error This Module only for OS/2
- #endif
-
- #define INCL_DOSDATETIME
- #include <os2.h>
-
-
-
- void dostime(int *hour, int *min, int *sec, int *hdths)
- {
- DATETIME dt;
-
- DosGetDateTime(&dt);
- *hour = dt.hours; /* current hour */
- *min = dt.minutes; /* current minute */
- *sec = dt.seconds; /* current second */
- *hdths = dt.hundredths; /* current hundredths of a second */
- }
-
- void dosdate(int *month, int *mday, int *year, int *weekday)
- {
- DATETIME dt;
-
- DosGetDateTime(&dt);
- *mday = dt.day; /* current day */
- *month = dt.month; /* current month */
- *year = dt.year; /* current year */
- *weekday = dt.weekday; /* current day of week */
- }